---
title: Environment variables
description: The environment variables are used to configure the application.
---

## Set up the file

The environment variables are used to configure the application. We will use a `.env` file to store the variables.

The variables are split up into the following sections:

- [General URLs](#general-urls)
- [Database](#database)
- [Authentication](#authentication)
- [GitHub SSO & Integration](#github-sso-&-integration)
- [SMTP Configuration](#smtp-configuration)

## Required variables

### General URLs

This section will cover all the variables related to the general URLs.

Name | Description |
--- | --- |
| `KANEO_CLIENT_URL` | The URL of the web application.
| `KANEO_API_URL` | The URL of the API.

### Database

This section will cover all the variables related to the database.

Name | Description |
--- | --- |
| `DATABASE_URL` | The URL of the PostgreSQL database.
| `POSTGRES_DB` | The name of the PostgreSQL database.
| `POSTGRES_USER` | The username for the PostgreSQL database.
| `POSTGRES_PASSWORD` | The password for the PostgreSQL database.

### Authentication

This section will cover all the variables related to the authentication.

Name | Description |
--- | --- |
| `AUTH_SECRET` | The secret key for the JWT token.


## Optional variables

### GitHub SSO & Integration

Name | Description |
--- | --- |
| `GITHUB_CLIENT_ID` | The GitHub client ID.
| `GITHUB_CLIENT_SECRET` | The GitHub client secret.
| `GITHUB_APP_ID` | The GitHub app ID.
| `GITHUB_WEBHOOK_SECRET` | The GitHub webhook secret.
| `GITHUB_PRIVATE_KEY` | The GitHub private key.

### Google SSO & Integration

Name | Description |
--- | --- |
| `GOOGLE_CLIENT_ID` | The Google client ID.
| `GOOGLE_CLIENT_SECRET` | The Google client secret.

### SMTP Configuration

Name | Description |
--- | --- |
| `SMTP_HOST` | The SMTP host.
| `SMTP_PORT` | The SMTP port.
| `SMTP_SECURE` | Whether to use SSL/TLS.
| `SMTP_USER` | The SMTP user.
| `SMTP_PASSWORD` | The SMTP password.
| `SMTP_FROM` | The SMTP from address.
| `SMTP_REQUIRE_TLS` | Whether to explicitly force to use TLS. [See more on](https://nodemailer.com/smtp#tls-options).

## Key points

- If you enable GitHub SSO, you need to set up the GitHub app which is used to authenticate users in the [GitHub Developer Settings](https://github.com/settings/developers).
- If you enable Google SSO, you need to set up the Google app which is used to authenticate users in the [Google Cloud Console](https://console.cloud.google.com/).
- If you have enabled SMTP, your sign in will be done via email using a magic link.
